package stripsPlanner;

import java.util.ArrayList;
import java.util.List;

public class StoredChoosing {

	private List<Integer> ListOfPicksIds = null;
	
	private int NrOfPredicateInSubgoalProver;
	
	private int IndexInList;
	
	public StoredChoosing(
		List<Integer> listOfPicksIds,
		int nrOfPredicate,
		int indexInList)
	{
		ListOfPicksIds = listOfPicksIds;
		NrOfPredicateInSubgoalProver = nrOfPredicate;
		IndexInList = indexInList;
	}

	public List<Integer> getListOfPicksIds() {
		return ListOfPicksIds;
	}

	public int getNrOfPredicateInSubgoalProver() {
		return NrOfPredicateInSubgoalProver;
	}

	public int getIndexInList() {
		return IndexInList;
	}
	
	
	public String toString()
	{
		String newline = System.getProperty("line.separator");
		String s = "\tList of picks for chooseOperator:";
		if(ListOfPicksIds != null)
		{
			s += newline + "\t\t";
			for(Integer i: ListOfPicksIds)
				s += i + " ";
			s += "\tIndexInList: " + IndexInList + ", Predicate: " + this.NrOfPredicateInSubgoalProver + ", ";
		}
		return s;
	}
	
	public StoredChoosing copyChoosing()
	{
		List<Integer> list = new ArrayList<Integer>();
		for(int i: ListOfPicksIds)
			list.add(i);
		return new StoredChoosing(
			list,
			NrOfPredicateInSubgoalProver,
			IndexInList);
	}
}
